package y2015.day_09.计算机;

public class Computer {
    private IMobileStorage storage;

    public IMobileStorage getStorage() {
        return storage;
    }

    public void setStorage(IMobileStorage storage) {
        this.storage = storage;
    }

    public void writeMobileStorage(byte[] data) {
        if (storage != null) {
            storage.writeData(null);
        } else {
            System.out.println("请插入移动存储设备");
        }
    }
}

